<%@ page pageEncoding="utf-8" %>
<%@include file="/commons/taglibs.jsp" %>
<!DOCTYPE html>
<html>
<fmt:bundle basename="res">
<head>
    <meta charset="utf-8">
    <title><fmt:message key='ttblsjxt'/></title>
    <jsp:include page="/WEB-INF/commons/commons-header.jsp" flush="true"/>
    <style>
        html {
            background: #fff;
        }
    </style>
</head>

<body>
<div class="layui-container">
    <div lay-filter="layuiadmin-app-form-list" id="layuiadmin-app-form-list" style="padding: 20px 30px 0 0;">

        <form:form class="layui-form" commandName="goods" id="form">
            <form:hidden path="id"/>

            <fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
                <legend><fmt:message key='jbxx'/></legend>
            </fieldset>

            <div class="layui-form-item goodsChannelArea">
                <label class="layui-form-label"><fmt:message key='splm'/></label>

                <div class="layui-form-mid layui-word-aux">
                        ${goods.goodsChannel.parent.parent.name} >> ${goods.goodsChannel.parent.name} >> ${goods.goodsChannel.name}
                </div>

            </div>

            <div class="layui-form-item">
                <label class="layui-form-label"><fmt:message key='spmc'/></label>
                <div class="layui-form-mid layui-word-aux">
                        ${goods.name}
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label"><fmt:message key='spbh'/></label>
                <div class="layui-form-mid layui-word-aux">
                        ${goods.goodsNo}
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label"><fmt:message key='spjg'/></label>
                <div class="layui-form-mid layui-word-aux">
                    <fmt:formatNumber value="${goods.defaultPrice}" type="CURRENCY"/>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label"><fmt:message key='scj'/></label>
                <div class="layui-form-mid layui-word-aux">
                    <fmt:formatNumber value="${goods.marketPrice}" type="CURRENCY"/>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label"><fmt:message key='tjhdjg'/></label>
                <div class="layui-form-mid layui-word-aux">
                    <fmt:formatNumber value="${goods.bargainPrice}" type="CURRENCY"/>
                </div>
            </div>

            <fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
                <legend><fmt:message key='spgg'/></legend>
            </fieldset>

            <div class="layui-form-item">
                <label class="layui-form-label"><fmt:message key='spsku'/></label>
                <div class="layui-input-block">
                    <table class="layui-table" lay-size="sm" id="feijin-sku-table">
                        <thead>
                        <tr>
                            <th><fmt:message key='gg'/></th>
                            <th><fmt:message key='sjbh'/></th>
                            <th><fmt:message key='kcs'/></th>
                            <th><fmt:message key='xsj'/></th>
                            <th><fmt:message key='hdkc'/></th>
                            <th><fmt:message key='tj'/></th>
                        </tr>
                        </thead>
                        <tbody>
                        <c:forEach items="${goods.skus}" var="sku">
                            <tr>
                                <td>${sku.skuNames}</td>
                                <td>${sku.code}</td>
                                <td>${sku.store}</td>
                                <td><fmt:formatNumber value="${sku.price}" type="CURRENCY"/></td>
                                <td>${sku.bargainStore}</td>
                                <td><fmt:formatNumber value="${sku.bargainPrice}" type="CURRENCY"/></td>
                            </tr>
                        </c:forEach>
                        </tbody>
                    </table>
                </div>
            </div>
        </form:form>
    </div>
</div>

<script>

    $(function () {

        layui.use(['form', 'laydate'], function () {

            var form = layui.form;
            var laydate = layui.laydate;

        });

    });
</script>
</body>
</fmt:bundle>
</html>